function addOptionTo(elem,val)
{
	var exist = false;
	for (i=0; i<elem.options.length; i++)
	{ 
		if (elem.options[i].value == val)
		{
			exist = true;
		}
    	}

	if (!exist)
	{
		elem.options[elem.options.length]=new Option(val, val, true, true);
		document = new input(val, val);
	}
}

function remOptionFrom(elem,val)
{
	for (i=0; i<elem.options.length; i++)
	{ 
		if (elem.options[i].value == val)
		{
			elem.options[i]=null;
		}
    } 
} 

function selectAll(elem)
{
	for (i=0; i<elem.options.length; i++)
	{ 
			elem.options[i].selected=true;
    	}
}
function changeTVSel()
{
	document.getElementById('curDom').value = document.getElementById('selectDomain').value;
	document.getElementById('curCon').value = document.getElementById('inputTV').value;
	document.getElementById('conceptForm').submit();
}

function changeDomSel()
{
	document.getElementById('curDom').value = document.getElementById('selectDomain').value;
	document.getElementById('curCon').value = 'change';
	document.getElementById('conceptForm').submit();
}

function subT()
{
	document.getElementById('curDom').value = document.getElementById('selectDomain').value;
	document.getElementById('curCon').value = document.getElementById('inputTV').value;
}
//
